#ifndef TILES_H
#define TILES_H



#pragma once
#include "d3dUtil.h"
#include <time.h>
#include "Node.h"
#include "Enum.h"
#define key_left DIK_LEFT
#define key_right DIK_RIGHT
class Tiles
{
	//Changed from private to protected
	private:
		D3DXVECTOR3 mTileCenter;
		D3DXVECTOR3 mTilePos;
		RECT R;
		void setRect();
		Node *node;	
		bool isNode;
		int buttonPress;
		int spellTypeRow;
		int spellTypeCol;
		TileType tileType;
		SpellType spell;
		int buttonRow;
		int buttonCol;
		int getButtonRow();
		int getButtonCol();

	public:
		Tiles(float x, float y, float z, TileType tileType, SpellType spell);
		Tiles(float x, float y, float z, TileType tileType, SpellType spell, bool coolDown, int nodeID);
		~Tiles();
		
		void setCenter(float x, float y, float z);
		void setPos(float x, float y, float z);
		float getX() { return mTilePos.x; }
		float getY()  { return mTilePos.y; }
		Node *getNode();
		RECT getRect() { return R; }
		D3DXVECTOR3 getCenter() { return mTileCenter; }
		bool isNodeTile(void) { return isNode; }
		void FreeNode();
		int getButtonPress();

		void setSpell();
		void setButton();
};

#endif
